﻿toggle = function (fsid)
{
    var div = $id("div_" + fsid);
    //var btn = $id("btn_" + fsid);
    //var load = $id("load_" + fsid);
        
    var display = "";
    
    if( div.style.display != "none" )
    {
        display = "none";
    }
    
    div.style.display = display;
    //btn.style.display = display;
    //load.style.display = display;
}

CC_New = function()
{
    //var load = $id("load_CCNew");
    //var btn = $id("btn_CCNew");
    if(confirm("save changes?"))
    {
        // di sini kirim data perubahannya
        //var input = getCCData();
        //btn.style.display = "none";
        //load.innerHTML = "<img src='" + LOADING.src + "' alt='' />"; 
        //cbkUFTNew_c.PerformCallback(input);
    }
}
ShowPopUp = function(iCPID, isNewCP)
{
    var div = $id("popuplayer");    div.style.display = "block";    div.innerHTML = "<img src='" + LOADING.src + "' alt='' />";    renderFirst();        cbkView_c.PerformCallback("SHOW" + DELIMITER + iCPID + DELIMITER + isNewCP);
}
closeCPInfo = function()
{
    var div = $id("popuplayer");    div.innerHTML = "";    div.style.display = "none";
}
cbkView_c_CallbackComplete = function(e){
    if( e.parameter.startsWith("SHOW") )
    {
        var div = $id("popuplayer");
        div.innerHTML = e.result;    }
    else
    {
        closeCPInfo();
    }
}